﻿using System;
using System.Collections.Generic;
using System.Text;

namespace GReporting.Core.PagingAlgorithm
{
   public class PageFooterBuilder:AbstractPageBuilder
    {
       public override void Build(PageBuilderContext context)
       {
           context.CurrentBand = context.Report.Layout.pageFooter;
           if (isPrint(context.CurrentBand, context.Engine))
           {
               context.Y = context.Report.Layout.pageHeight - BandPrintHeight(context.CurrentBand, context.Report.Layout, context.Engine);
               int printBandHeight = PrintBand(context);
               context.Y += printBandHeight;
               context.PrintHeight += printBandHeight;
           }
           context.NextPageSet();
           AbstractPageBuilder builder = new TitleBuilder();
           builder.Build(context);
       }
    }
}
